﻿using System.Web.Mvc;

namespace Tau.Web.Areas.Admin2
{
    public class AdminAreaRegistration : AreaRegistration
    {
        public override string AreaName
        {
            get
            {
                return "Admin";
            }
        }

        public override void RegisterArea(AreaRegistrationContext context)
        {
            context.MapRoute(
               "Adm_Default", // Route name
               "Admin/{controller}/{action}/{id}", // URL with parameters
               new { controller = "Image", action = "Index", id = UrlParameter.Optional } // Parameter defaults
           );

            context.MapRoute(
               "Adm_GetImage", // Route name
               "Admin/{controller}/{action}/{id}/{type}", // URL with parameters
               new { controller = "Image", action = "GetImage", id = "", type = "" } // Parameter defaults
            );

            context.MapRoute(
               "Adm_DeleteImage", // Route name
               "Admin/{controller}/{action}/{id}/{mode}", // URL with parameters
               new { controller = "Image", action = "Delete", id = "", mode = "" } // Parameter defaults
            );

            context.MapRoute(
               "Adm_ImageFrame", // Route name
               "Admin/{controller}/{action}/{mode}", // URL with parameters
               new { controller = "Image", action = "ImageFrame", mode = "" } // Parameter defaults
            );
        }
    }
}
